Tracking Forums, Newsgroups, Maling Lists
Home Scripts Tutorials Tracker Forums
 
  HOME    TRACKER    MYSQL




Very Easy Question - Assigning A Base A Username And Password In PHPmyadmin


Maybe I am just getting very tired all of a sudden, but I have forgotten how to assign and username and password to a MySQL base - can someone please put me out my misery on how to do this




View Complete Forum Thread with Replies

See Related Forum Messages: Follow the Links Below to View Complete Thread
Username And Password For Phpmyadmin
I have to put a password and username for that php page where is index for phpmyadmin, my site is on some german windows server, which is user-nofriendly, no support, so these guys can not help me. I tryed with http auth or cookies, its not working, only config (which is without password. If i use http authentification, i allways have a small window for user and pass, but if i write a proper user/pass it pop up again, like its not a good pass or user.

Password/Username Locked Me Out Of PhpMyAdmin
I'm using MySQL 5.X on a Mac. I was trying to create a password and username for a new database. I created the database, then clicked on Privileges. Next, I created a password and username.

Not only can I not access the database, I can't even access phpMyAdmin now; I get this error message:

Username & Password
i've jz installed mysql query browser and it requires me to fill in username n password, but i can't remember of setting any username b4...wat shud i do?

Username/Password
I am practising both PHP and MySQL programming on my desktop with Windows 98SE / PWS 4 Web Server. Using PHP script to connect to MySQL server, when I define DB_USER and DB_PASSWORD with my real user name and real password, I get the following error message:

Warning: mysql_connect(): Client does not support authentication protocol requested by server. Consider upgrading MySQL client in D:Inetpubwwwrootphpmysql_scripts6mysql_connect.inc on line 20
The category could not be added!

To get these to work, I had to change DB_USER name to "root" and DB_PASSWORD to blank.

Finding Username And Password
i havent used it for since ive installed it and i forgot my username and password. is there any way of finding this out and how?

Checking Username/password
I have this sql statement:

SELECT * FROM projects WHERE `username` = 'FAA' OR `username` = 'faa' AND `password` = 'ASW2004' OR `password` = 'asw2004'

in order to check for whether for the correct combination whether the user used upper or lower case. It's returning 2 rows from the database but that combination occurs only for one row. Do I have my syntax wrong?

Username And Password Verification
I am querying a table on two fields, Username and Password to validate a site log-on attempt. Is there a way of verifying that a record matches apart from running through a fetchrow_array() loop?

Two Databases, One Username And Password
I have two databases that both require a username and password. The one database I just created and would like to have the usernames and passwords in both to be syncronized.

Username, Password And Database Name
but the person that installed mysql on my laptop told me that the username and database name was not that important. Is there a way to retrieve my username, password and database name? Im trying to practice php and mysql but it give me an error.

Warning For Wrong Username/password
When a user types in a wrong username or password, the following happens:
Warning: mysql_connect(): Access denied for user: 'h@WEB1' (Using password: YES) in C:Program FilesApache GroupApache2htdocsprocuraloginResults.php on line 118

Warning: mysql_select_db(): supplied argument is not a valid MySQL-Link resource in C:Program FilesApache GroupApache2htdocsprocuraloginResults.php on line 120
Invalid UserName or Password Please Try Again Click Here

is there anything i can do to just make the
Invalid UserName or Password Please Try Again Click Here

Mirroring Username Password Fields
I have 2 databases that I do not want to have to create an account if it already exist.. I'm wondering if we can mirror the 2 fields. username and passwords.

Making Mysql Username And Password
im setting up phpAdsNew and they ask for my database (mysql) username and password...
i go to google and search on how to create usernames and passwords and i choose the link on mysql.com...

it tells me to do this:
GRANT ALL PRIVILEGES ON database TO 'username'@'localhost' IDENTIFIED BY 'password' WITH GRANT OPTION;

i do that and all goes well...i go back to the installing of phpAdsNew and put in the username and password i made...

it still doesnt work... so could someone tell me if thats how to make a username and password in mysql or if there is something wrong with phpAdsNew... and i'm using the mysql command line client to put the code in...just incase you need to know that.

MySql Username / Password And Config
Firstly USERNAME AND PASSWORD? You define them where? Edit them where?

http://localhost will not work on my computer, how can I make MySql run from 127.0.0.1 ?

Lost Username And Password To MySQL Server....
I have been using the MySQL control center and had my usernames and
passwords for the MySQL server stored in the control center.
I recently lost everything on my PC including the usernames and
passwords.

Does anyone know if there is a way to reset or remove the passwords
from MySQL so that I can make new ones? I do have the root password for the server that MySQL is running on.

Lost Username And Password To MySQL Server....
I have been using the MySQL control center and had my usernames and
passwords for the MySQL server stored in the control center.
I recently lost everything on my PC including the usernames and
passwords.

Does anyone know if there is a way to reset or remove the passwords
from MySQL so that I can make new ones? I do have the root password for the server that MySQL is running on.

Just Installed MySQL And Administrator, GUI Tools Want Username Password.
I just installed MySQL and the GUI Management tools. The tools are asking for a username and password. What username and password? The only password I entered during install was for something else I believe?

Have To Set Password In Phpmyadmin
I am using php4 and mysql and running them in IIS. I installed all in C:.
Then I put phpmyadmin folder into the wwwroot folder. When I login http://www.mysite/phpmyadmin then it display the login page of username & password. If I keep blank those 2 fields it just direct enter to the "welcome page" of the phpmyadmin & doesn't show any option to change password or other option of the mysql. So the problem is any one can login directly to the database of the mysite.

Please tell me what should I do???

Is it for mysql setup (its userid & password), or php setup or itegration os there version or something else?

Implement Password On Phpmyadmin
we all work in a network environment.
we all can access phpmyadmin of any other.
is it possible to implement password on it.
i want if anybody try to access my phpmyadmin e.g.(aamir/phpmyadmin, aamir is my system name), a dialogue box of password will come.
if he enters the right password, he can access that.

Lost Phpmyadmin Password, Can't Do Backups!
I'm trying to run a backup on a bitrock install sugarcrm on linux.
apache is running on port 8888, i try to get into phpmyadmin but it
asks for user and password.

I don't know what the user/password is. I saw user file so i know user
= administrator. but I don't know password.

I have access to the httpd.conf file. I see the last part of the file
concerns authentication for phpmyadmin. Is there a way to turn off
authentication? I just need to get a backup.

I also try to use the command line but i get error 2202. it can't read
the /tmp/mysql.sock file.

i know mysql works because sugarcrm works fine from a browser.

Trouble Assigning Value
in my code i have the following:
tableName!Date = "2006/12/07", where "Date" is the name of the column in the mysql table and it is defined/has a type of datetime..

When i get to this line of code however, the value of date stays null. Ive managed to assign other fields in the table similarly (e.g. tableName!fname = "Frank".) I believe it may also be a keyword and thats my problem, but I'm uncertain.

Does any one have any suggestions as to why this wont work for the date field?? If its due to the fact its a keyword, how can i still pass the value without changing the column name in the table?

Assigning Index
I think there is a simple answer to this, but this is an issue I haven't had to explore as of yet for some reason.I am in the process of importing a batch of new records into the database and I need to assign a unique value in one of the fields that will serve as the primary key. The field where this value will appear is obviously already the primary key field and the records in the database already have a unique value found there.

For the life of me, I can't figure out how to assign a unique value for the primary key of these newly imported records that will not duplicate the primary key found in the existing records.

Assigning Status As Reserved
-------
tbl_dates.id
tbl_dates.week_date
--------
tbl_cottages.id
tbl_cottages.cottage_name
--------
tbl_booking.id
tbl_booking.cottage_name
tbl_booking.book_date
-------
tble_dates.week_date contain dates in the format 'January 1 - January 7'.

the tble cottages contain a list of properties

the tble_booking contains entries which I input when a cottage becomes booked so I know when the cottage is unavailable on what dates.

What I want to be able to do is cross reference the top 2 tables against tble_booking.

So if the tble_booking contains
ID = 1
Cottagename: Bluebells
Week_Date: January 1 - January 7

If some one clicks on the webpage to check the availabilty for the week 'January 1 - January 7' the cottage will be marked 'reserved' and the rest will be marked 'available'.

I have tried doing it with a LEFT OUTER JOIN but it marks them all as reserved?

SELECT
tbl_cottages.id,
tbl_cottages.cottage_name,
tbl_bookings.id,
tbl_bookings.book_date,
tbl_bookings.book_cottage,

FROM tbl_cottages

LEFT OUTER JOIN
tbl_bookings ON tbl_bookings.book_date = tbl_cottages.cottage_name

WHERE tbl_bookings.book_date = '#URL.calendar_date#
If you need any more info please ask!!

Unknown Column (assigning Using AS)
SELECT
u.user_id,
u.user_name,
(
SELECT COUNT(friend_from)
FROM friends
WHERE friend_from = u.user_id
) AS friends_added,
(
SELECT COUNT(user_referered)
FROM users
WHERE user_referered = u.user_id
) AS friends_referered,
friends_added + (friends_referered * 10) AS points
FROM users u

Quote:

#1054 - Unknown column 'friends_added' in 'field list'

Assigning Userids To Existing Table
I have a table of existing users in a database. I want to add a "userid" column to the database that automatically assigns an ID to each user when new accounts are added to the system. I know I would do something like this if I had the brains to have added the column at the time of creating the table:

ALTER TABLE writers ADD (
userid int PRIMARY KEY auto_increment
);

However, the table is now already active with users, and I want userids assigned to existing accounts on the system.

Assigning Foreign Key After Completion Of Table
I know how to assign a primary key after completion of a table does anyone know how to set a foreign key?

Assigning Query Results To A Variable
I would like to Execute this Select Statement...

SELECT MAX(VisitorID) FROM Visitors.

Is there any way to store the result directly into a VB variable??

lngVisitorID = ???

Assigning Query Results To A Variable
I would like to Execute this Select Statement...

SELECT MAX(VisitorID) FROM Visitors.

Is there any way to store the result directly into a VB variable?

Assigning Foreign Key After Completion Of Table
I know how to assign a primary key after completion of a table does anyone know how to set a foreign key??????

Assigning Unique ID To Distinct Values
I have a table `books` with booktitle and authorname columns. In my
applicatoin booktitle has unique values but authorname doesn't. ie an
author can have many books but not the other way around.

I need to add more author info in the database. So I need a new
`authors` table with authorname as a column (along with address, email,
phone etc) and an authorid primary key. Then I need to replace
books.authorname column with a column containing the corresponding
authorids

How can this be done in sql?

Assigning User Privileges Error
I created a user 'cody' % and localhost and try to assign privileges to his database 'cal_cody' For some reason it don't work, posting this weird thing in forums didn't help either.

so I tried:

mysql> GRANT ALL PRIVILEGES ON cal_cody.* TO 'cody'@% IDENTIFIED BY 'access';
Query OK, 0 rows affected (0.00 sec)

also tried:

mysql> GRANT USAGE ON cal_cody.* TO 'cody'@'%' IDENTIFIED BY 'access'
Query OK, 0 rows affected (0.00 sec)

then tried the same for 'localhost' then even flashed the privileges and even reloaded the mysql service doesn't do jack

Is there something wrong with my command, or is there a way to do this through phpmyadmin?

Help In Assigning Unique Keys To Table Entries
Allow me to share some design problem that I am facing.
I have the following table definition:


CREATE TABLE `image_info` (
`Image_ID` int unsigned not null,
`Title` varchar(255) default '' not null,
PRIMARY KEY (`Image_ID`)
) ENGINE=MyISAM DEFAULT CHARSET=latin1;
This simple table holds information about images. Each image has a title.
Note that the primary key was NOT defined as auto_increment (explanation below)
Also note that the table engine was defined as MyISAM (a system requirement)

The range of image IDs that can added into the table is split into 2:
1) IDs 1,000,000 and above are reserved for images that come from an external program
which defines the IDs.
2) IDs 1 - 999,999 are reserved for images uploaded by users in runtime in my site.

This means:
When I add an image from my application (1), I already know in advance what Image ID I need
to use and I can safely add it using:


insert into image_info (Image_ID, Title) values (1000010, 'I am a photo from an external program');
I know that image ID 1000010 is reserved just for that photo and so there won't be any duplicates.

When a user uploads a photo to my site (2), that photo needs to be stored in the table
with the next available ID which is < 1,000,000.
I use the following query:


select max(Image_ID) from image_info where Image_ID < 1000000;
I then add 1 to the value I am getting and this is the ID I will use for the image uploaded by the user.

The problem occurs when too many users are uploading photos at the same time.
This is a problem of atomicity. 2 Users may be assigned the same "free" image IDs and then
one of the queries will fail when adding the record to the table because of duplicate IDs.

I cannot change the order of the ID ranges (making 1 - 999,999 for my external program and 1,000,000 and above
for images uploaded by users), as this is a system requirement.
If I didn't have this requirement, I could have set auto_increment on the image_id field.

I am looking for a solution to my problem.
Can anyone think of one?
Maybe using an additional table which uses auto_increment to assign IDs?
I am developing in PHP, so maybe I need an application-level solution on top of MySQL


Assigning Primary Key In MySql After Completion Of Table
I finished completing a large table with 155 rows in it. But I forgot to assign a primary key. Does anyone know how to do this? i 'm think I might need to use an alter function but can't figure out what to put in the command.

First Base
I'm trying to follow some simple instructions but I just can't seem to get anywhere. I'm running it through XP, I've installed it and can get into winmysqladmin no problems at all. It didn't ask me for a password or anything when I started which some of the books suggested.

I set up a user s_roper with a password and went into the command prompt to create a database. I typed in the username and password and it was all correct but it just keeps saying access denied. I set up the root user and set a password for that but it keeps saying the same :access denied for user: 'root@localhost' <using password: Yes>

So I decided perhaps I'd done something wrong so I removed it and started again but it seems even when I remove it it still holds the passwords and users.I'm completely stuck.

Help With A (probably) Easy Query
I am trying to write a query to run through phpmyadmin. What I have is this:

In table "vb_user" I want to pull the data in field "username" and copy that username in another table called "vb_userfield" in a field called "field5". Both tables share the field "userid" which is how the relation is made. I know this is probably very simple but man... I just can't seem to pull it off.

I've got about 500 members and I really want to populate that field "field5" with thier username without having every one of them doing it manually.


Easy Query...probably
I've got three tables:

- events
- tasks
- docs

Events are made up of one or more tasks and tasks may or may not have docs.

What I need to do is get all the events with associated tasks and docs.

QUICK AND EASY ONE
im fairly new to php/mysql so please bear with me
I am trying to upload a txt.file created from an excel spreadsheet using the following query:

LOAD DATA INFILE 'path/file.txt' INTO TABLE my_table;

im getting a syntax error!
what could be wrong? are there any other attributes i should be adding to this query? i also tried uploading a csv version of the same file and get the same error.

Recreate Data-base?
if i build a temprorary DB on my server for a clients site while i create it. is there someway i can make the DB give me a creation code that i can give to the client to re-create my entire temporary DB?

/var/lib/mysql/base-bin Files?
I run a hsoting company and we have a dedicated server. Our server details are at below:

OS: CentOs 4.5

Recently I have discovered server disk usage is getting bigger with no reason. I have googled the issue and find out exim temp files were getting very big. I have deleted them.

Also I have figured out /var/lib/mysql/ directory is another large directory. In the directory there are base-bin files. Can you tell what these base-bin files for. I do not think they are neccessary for server but I did not want to delete them without knowing what they really are.

Restore To New Data Base
I am using a heavily modded PHPBB forum and want to convert all my posts, users, etc, into a new PHPBB forum using some other mods. I am using MySQL 3.23.58 .

I ran the conversion steps as the creator fo the modded forum stated but at the point where I run the install.php page I get an error that says "installation aborted as table xxxxxx already exists."

Is there a way around this like perhaps makign the new tables over write the old tables? I need to keep the tables as they are or I will lose the posts and such.

One Big Data Base Or Many Smaller Ones
I am creating an on-line course and would like to know if it will make a
difference in the way I set up my database(s).

Option 1 : Create one large Database for the course

Here I would prefix the tables with their functions, ie. reg_ quizzes_
forum_ etc.

Option 2 : Create a smaller Database for each function

Here I would create a registration database, a quizzes database a forum
database etc.

I do not have my own server, so I would have to get my ISP to create
each database, which might be a hassle for them.

Data Base Transfer
Im trying to learn if it is possible to transfer data from one mysql to another with a diferent structure ie different table names etc am I beating my head against a brick wall? .... its thick enuf.

LINKs For A Data Base
I am trying to create a database that have email addresses. I would lie it so that when some one clicks on the email address, it would open up the email ( mailto:xxxx.xxxxx.com) , yet I want it to display as xxxx.xxxxx.com (as a hyperlink)
The above answer might answer the next quest, but if not please advise on it as well.
I would like to create a link to a different page in a table (pictures of people), again, this should be a hyperlink.

Easy Way To Delete Duplicates?
I had 2 membership db's. One had all the members (65K) db2 had all the members that have registered on the website. I am wanting to consolidate the two.

Basically i took both, and merged them together into their own db. now the membership list is about 80k. 20k or so of that are duplicates. My idea was to export the thing as .xls and remove the duplicates via Microsoft Excel. However, Excel has a limit of 65Kish rows. so i can't really go about that.

Select Row From Table, EASY
I'm drawing a blank and can't find it my Sams 24 hour book.

I've got a player name and stats in a DB so a row in the database would look like
Chris Brown 300 1200 5 40 325 2

I need to select(display PHP) Chris Brown and everything associated with him.

I had this all setup and haven't thought of it in years and now....geesh I just feel like an idiot as nothing I've tried works and I know it's connect to DB then one line of code, a select statement.

Pros/cons (easy ?)
Say you have a double opt in mailing list, of which the subcriber list is
store in the db. Im still somewhat of a newb, so bear with me... are there
any pros/cons as to keeping the 'unverified' subscribers in a different
table, aside from organization?
I did just that, where, when they subscribe, they are put in a temp table,
and them moved to the real table once verified (and the temp entry deleted).
At the time, I did this thinking organization of data... but as an
afterthought, am thinking I just did a lot of unecessary coding... ... and
am thinking just an y/n field for verified or not in the primary table would
suffice.

It's not actually a mailing list, just thought that'd be the easiest
example.... the main table holds about 1000 entries, and there about 10-20
temps/days. The only con to my setup I can think of (again, as an
afterthought) is deleting the unverified entries after a week and the extra
resources of going through the entire db searching for the week-old
unverifieds, but with the size of my db, I dont even think that is a con in
my case.

Did I waste a lil time there w/ the extra table?

Create User Easy?
Is there an easy way I can just create a MySQL User... and give him the privledges to only do things to databases that he from now on creates..?

Or is it gonna be every time I create a database I would have to give him privledge to that database? What type of route would I have to go with that...

Also when his user connects to the MySQL Server is there a way I can do a SHOW DATABASES and show only the databases that he has created? He needs to also be able to Create/DELETE/APPEND/UPDATE any database that he creates.

What's the easiset way about going around this route? Am I going to have to Grant him Permissions on every database that he creates? Does the root account have to grant the permissions?

I Think It's An Easy To Fix Sql Syntax Problem
can anybody help me :

@mysql_query("INSERT INTO leden WHERE gebruikersnaam = ".lekubb($_POST['gebruikersnaam'])." (status) VALUES (Global Admin)") or die(mysql_error());

Ik get this error :
You have an error in your SQL syntax. Check the manual that corresponds to your MySQL server version for the right syntax to use near 'WHERE gebruikersnaam = t (status) VALUES (Global Admin)' at lin

You can see the script online at http://www.webmasterhelp.be/systeem/testje.php
When you fill in something and press enter you'll see the error.
If you need more info or something you can mail me at arne_dejongh2@hotmail.com or post something here.

Easy Collation Changing.
A while ago, I messed around with collations etc, without understanding the rammifications.Ended up with some tables swedish, some general and others, but all were under Latin1. After some time a few queries started breaking. Anyway, I played and tinkered and eventually managed to fix.
The problem was that I couldn't go and Alter thousands of columns manually, so a PHP script was created, and works fine.
But for the sake of knowledge, is there a way to change the Character Set and Collation stuff of an entire database(s) quickly and easily using SQL?

Anyone Using OpenOffice BASE As MySQL Frontend?
I recently saw OpenOffice's Base:

"BASE enables you to manipulate database data seamlessly within OpenOffice.org. Create and modify tables, forms, queries, and reports, either using your own database or BASE’s own built-in HSQL database engine. BASE offers a choice of using Wizards, Design Views, or SQL Views for beginners, intermediate, and advanced users ... For more advanced requirements, BASE supports many popular databases database natively (Adabas D, ADO, Microsoft Access, MySQL)"

I' am interested to hear anyone's experience with using this as a tool, development tool, or front-end builing tool for MySQL apps.


Copyright © 2005-08 www.BigResource.com, All rights reserved