Jump to content

Recommended Posts

Posted (edited)

Hello!

I'm using the great mysql.au3 by cdkid and I want to ask how is the easiest way to change a value from a table. The first thing I've thought is to do something like this

$vals=_GetColvals($sql, "table", "column")
$vals[3]="Newval"
_DropCol($sql, "table", "column")
_CreateColumn($sql, "table", "column", "no", "Text(32)", "no", "no", $vals)

but I'm sure there is a easiest way than to drop the whole column and then insert it again. Probably using queries and something like that INSERT ... WHERE ... but I'm really bad with query's syntax so would someone that is good with it please help me?

Thanks

p.s. Sorry for my English I'm still learning it

Edited by muhmuuh

I ran. I ran until my muscles burned and my veins pumped battery acid. Then I ran some more.

Posted

lol just found out

"UPDATE example SET age='22' WHERE age='21'"

I guess this solves my problem.

I need to find one of those t-shirts that say 'i'll ask google before asking stupid questions'

If the mods decite this topic is pointless - please delete it.

Anyway I hope this helped someone else too.

Sorry for the spam

I ran. I ran until my muscles burned and my veins pumped battery acid. Then I ran some more.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...