how to compare a datetime fields where datetime now or I need to translate into a timestamp for compare
MySQL 5 is out? I'm still using MySQL 2.
lol
seekwill, but item_types is ok right?
I guess
There's not much to say about it
There is going to be like 20 types, and who knows how many items will be added to the database and I think it's dumb to search the database with WHERE type = 'Guitar' when I can search using an integer instead.
ok?
dev.mysql.com is sloooow.
I can't load the page.
s2bu
I'm probably going to reference everything by it's ID so I don't think I need indexes.
Yes you do
Really?
Do you want me to repeat myself over and over?
The primary key index isn't enoguH?
enough even
For item_types, the PK will be enough. But not the other table that references those IDs
some ideas to my problem?
What problem?
You didn't give all the info
…
I want to know exactly what you want, with examples.
32 post above or so
Copy and paste will be you friend…
50,7,14,15,'' ; 51,7,14,11,''
french channel ?
#mysql.fr ?
!tell iskywalker about enter
iskywalker The enter key or return key is not a substitute for punctuation. Use a period '.', comma ',', colon ':', semi-colon ';' emdash'–', or elipsis '…' instead. In other words: DON'T HIT ENTER UNTIL YOU'RE DONE.
no
i want to insert or update x,7,14,15,'' ; x,7,14,9,''
i want to delete the 2nd record in table 'messages' which satisfies the criteria
what is wrong with ' delete from messages (select * from messages where receiver='greenberet' LIMIT 2);
'
Why do you need a SELECT in there?
!m Greenberet delete sy
Greenberet see http://dev.mysql.com/doc/refman/5.0/en/delete.html
maybe just a where is enough
a where??
The x is the PK?
i want to delete those record from messages
yes exactly
Update the last column to ''
delete from messages where receiver='greenberet'
but i want to delete the second record where receiver=greenberet
well yes, but i must do an insert also
INSERT… but if it already exists…?
the first yes, the second not
i want to delete the 2nd record not all the records
huh?
will you please solve my little doubt
Greenberet, why don't you have an ID in your table?
delete from messages where receiver='greenberet' limit 2, 1??
the ?? means i am not sure at all
iskywalker, i doubt that is going to work the way he thinks it will
thats because i did not make the table, and i dont want to modify a couple of pages
i dont want a where
Greenberet, you don't want a where?
Greenberet, what?
why should a where be in the command? cant i delete from messages certain number of tuples
and that query didnt work
Greenberet, I don't think anyone understands what you're talking about.
Greenberet, You clearly don't understand basic SQL.
lisson, i have a table messages and i want to delete the second message whose reciever is greenberet
so please suggest a query
Greenberet, I told you what to do
Greenberet, If you aren't going to listen it doesn't bother me any.
u told me what to do??
when??
Greenberet, Your table needs an id.
i know, i know but i have to change a lot of stuff to put an id
Greenberet, How is that my problem?
i am sure there will be some other methos
it aint your problem
but please suggest some other method which dont require an id
Greenberet, I'm not going to help you create that monster you call a database.
i did not create it
I don't care who created it.
lisson, please suggest a method
Greenberet, You should be getting paid by the hour.
Greenberet, Then you get paid to make changes like this.
lisson, why such a big fuss
over a litle thing
Greenberet, It's not a little thing. It's a big deal.
Use WHERE. It's there for that purpose.
!m Greenberet delete
Greenberet see http://dev.mysql.com/doc/refman/5.0/en/delete.html
And read the docs.
seekwill, Hi again.
I added indexes to my tables.
You are the man
unique(item_id, item_name, item_type_id, item_profile_id)
I'm not sure if that does what I think it does though.
It creates a unique constraint on those fields.
On those fields combined together?
Yes
I thought so
I was just making sure
So why did you ask?!?!?!
I remember having problems with unique constraints before
Plus no one else is talking so we have to pretend that php mysql web hosting discussion is occurring.
No we don't
Yes we do
No
We
Don't
The freenode police will get mad.
Who day???
They'll take away our red stapler.
We don't need no red stapler
They are listening!
5AM. I have to leave for a flight in…4 hours…
So your plan is stay up all night
so you can sleep during your flight?
No. Can't sleep on the flight
Well, shouldn't.
No?
Well, why not???
Flying to the east coast. When I get there, it'll be 5PM… and pretty soon I'll need to sleep again…
I know. Isn't it great?
no
Oh.
If sleep was so great, I'D BE DOING IT RIGHT NOW
Well I sleep on planes all the time.
You are awesome
what is wrong with this query
delete from messages using tmptable, messages where (messages.bookid,messages.sender,messages.receiver,messages.message,message.mdate) in tmptable;
At least he's trying
will you tell me whats wrong with that
no
and why not?? are you cross with me?
for not having an id?
That's brian, not me.
I have a million of things to do. I don't have time to hold your hand.
I'm pretty sure the manual gives you examples of how to do it.
everything is given in the manual
everything is given somewhere on the web
then whats the use of this room
??
To talk about our ex girlfriends
grrrrrr
its a good thing you are not in front of me
for such a simple thing you are beating round the bush
If I was in front of you… I would run. I don't mess with people in green berets
If it's so simple… how come you don't get it?
i'll get it Mr. seekwill. i'll seek the answer
Great!
my ex girlfriend was such a dumb slut
oh great is it. well you just sleep on your plane
you will see my query in your dream
abstrakt , this is a mysql room
Greenberet, really? i thought it was for bitching about our ex-girlfriends, my bad
bGreenberet, really? i thought it was for bitching about our ex-girlfriends, my bad/b
hahaha, i'm gonna write an irc client and call it BitchAboutYourX
it'll be a whole new paradigm in IRC communication. whatever you try to say over IRC, BitchAboutYourX will permute it into whatever it feels like it wanted you to say and then send that instead.
weird syntax e.g. the comma placement and the where clause order… and you don't ever actually identify a row anywhere in that query.
Greenberet, you're just listing column names… you might as well run: TRUNCATE messages;
Oh look, bags packed.
!fooP
Greenberet, what are you actually trying to do? like, in plain english. what is your goal?
seekwill still no suggestion for my problem?
as a mysql client, is there a way i can tell the server to ignore insert/update queries i run on certain tables?
or, parse the sql hosting and discover which tables it applies to?
hey all
_mary_kate_, hey is ashley there?
SELECT `id` LIKE '14849' ?
i wanna say SELECT `id` LIKE '14849, 1234, 134345, etc'
D3ADLiN3, select id from table where id in (1,2,3,4)
ok thanks ill give that a try
pr use or SELECT `id` LIKE '14849' or id like '1234, 134345, etc'
… probably better to do IN
given that he's selecting based on a sequence of numeric IDs LIKE is probably not what he wants
D3ADLiN3, though technically you could make it work either way, i think IN is more appropriate than LIKE
it's wildly different
LIKE without wildcards is essentially useless
i wonder where you got yours, like doesnt carry about lower or upper case, so there is a difference, i hope D3ADLiN3 knows it.
Is it possible to make MySQL auto increment in base 36 instead of base 10?
i got it working thanks
iskywalker numbers have upper and lowercase ?
iskywalker just FYI, IN or = don't care about case either, if you set your collation sensibly
well he didnt say anything about it
iskywalker true!
but only crazy people - or geeks - use CS collations
hello, how to compare a datetime fields? where datetime now() ? or I need to translate into a timestamp for compare?
no
- why not?
'because you can't'
auto_increment is integer based
MinuteElectron just silently do a 1 / log 36 in your head…
base 36 is 'alphadecimal'
err
can someone help me with this:
MySQL server has gone away
No connection. Trying to reconnect…
i dont see anything in the .err file that shows why its dying
!man gone away
see http://dev.mysql.com/doc/refman/5.0/en/gone-away.html
http://pastebin.ca/619022
i tried new connections.. it doesnt work
its only when i request something on stored procedures
direct access to the db works fine
heck.. the sp is corrupt
ERROR:
No query specified
when i try to show create procedure
that was a working procedure.. i used to use it all the time
is there a way to fix the procedures file or something?