Search Results

Showing results 1 to 40 of 44
Search took 0.01 seconds.
Search: Posts Made By: baki100
Forum: MySQL 2 Days Ago
Replies: 1
Views: 165
Posted By baki100
learning the code will probably take you a year max but you should also learn about database concepts and principles (eg. normalization, database integrity, design etc)
the problem though is that it...
Forum: Python 2 Days Ago
Replies: 4
Views: 160
Posted By baki100
did you get an exception that mentioned something about indentation because in python you have to have the executable code under the if statement. you don't need the brackets as well
try this:

if...
Forum: Computer Science 2 Days Ago
Replies: 3
Views: 139
Posted By baki100
i don't see a problem but bear in mind that those are two completely different languages and bear little similarities but it should be a problem seeing that is intro classes.
Forum: MySQL 4 Days Ago
Replies: 4
Views: 277
Posted By baki100
you can build a anonymous block or procedure to do this as well
Forum: MySQL 4 Days Ago
Replies: 2
Views: 211
Posted By baki100
i suggest building the sql query or non-query so that when it fails you can print the query and check whats happening, its usually a problem with the way the query is built.
Forum: MySQL 6 Days Ago
Replies: 1
Views: 296
Posted By baki100
try this:
call GetOffice(@countryId:=1,@countryName:='India');
Forum: MySQL 8 Days Ago
Replies: 2
Views: 291
Posted By baki100
Unneeded; because you require j_num from the journals tables you are already linking the table with researchers table. That join should suffice to return the information you required. If you wanted...
Forum: Python 24 Days Ago
Replies: 7
Views: 249
Posted By baki100
dude just combine everything snippsat posted he basically wrote you the programme it's right there, just think about it
create a loop from 1 to 100
generate random number and store in a variable...
Forum: MySQL 29 Days Ago
Replies: 1
Views: 529
Posted By baki100
i think you might want to have a look at cursors, can't think of anything else at the moment though, sorry.
Forum: MySQL Oct 21st, 2009
Replies: 1
Views: 364
Posted By baki100
For instances like this i always suggest using anonymous blocks or stored procedures and you are probably most likely going to need an if statement
Forum: MySQL Oct 20th, 2009
Replies: 2
Views: 652
Posted By baki100
try to convert it as a date in the insert statement by using this function:
str_to_date('30 Jun 2009','%d %b %Y')
Forum: Database Design Oct 16th, 2009
Replies: 6
Views: 662
Posted By baki100
ouch you use chen model i'll have a look at it and try and make out heads or tails from that doc
Forum: Database Design Oct 16th, 2009
Replies: 6
Views: 662
Posted By baki100
well the first apparent error i see is the many to many relationship between the book and customer as one book can be loaned by many customer and a customer can loan many books, it is also not...
Forum: MS SQL Oct 16th, 2009
Replies: 2
Solved: mysql to mssql
Views: 609
Posted By baki100
migrating from one rdbms to another is not as simple as dumping the sql scripts in the new rmdbs, unless you convert the entire script by hand a simpler solution is use a migrator tool to migrate and...
Forum: Python Oct 16th, 2009
Replies: 8
Views: 483
Posted By baki100
for your first question

start = int(raw_input("Start at: "))
end = int(raw_input("End at: "))
count = int(raw_input("Count by: "))

while start <= end:
print start
start =...
Forum: MySQL Oct 16th, 2009
Replies: 3
Views: 447
Posted By baki100
so first you will have a user table that links to a favourite_table that has the user id and a product category id that links to a product_category table in this table you a product category id and...
Forum: MySQL Oct 15th, 2009
Replies: 3
Views: 447
Posted By baki100
i don't think MySql has built in email functions like Oracle's PL/SQL so instead you will have to do it from the front-end system which i assume is php.
Forum: MySQL Oct 15th, 2009
Replies: 5
Views: 437
Posted By baki100
the f and m are synonyms for those tables the join is at the AND statement
Forum: Python Oct 15th, 2009
Replies: 3
Views: 198
Posted By baki100
or you can reverse the slash like such
C:/HourlyATC/ etc
Forum: MySQL Oct 15th, 2009
Replies: 5
Views: 437
Posted By baki100
try this i think it's just a little less complex than the inner join syntax

SELECT m . *
FROM members m, friends f
WHERE f.friend1 =1
and m.member_id = f.friend2
Forum: Python Oct 15th, 2009
Replies: 12
Views: 468
Posted By baki100
because the if statement will never equate to true person is a list and pname is a string.
Forum: Python Oct 14th, 2009
Replies: 4
Views: 190
Posted By baki100
just a point of interest have a look at the time() module it has very nifty function called strftime, then you could have something like this:

date = time.strftime('%m/%d/%Y',time.localtime())
Forum: Python Oct 14th, 2009
Replies: 3
Views: 219
Posted By baki100
you have to convert the num variable to a string
like such:
even_file.write('%s\n'%num)
Forum: MySQL Oct 13th, 2009
Replies: 1
Views: 403
Posted By baki100
this is a bad example, instead you should have a look at composite entities then.
in short hand notation a better design for you above example would be:
main(id,fname,uid,cid)...
Forum: MySQL Oct 9th, 2009
Replies: 9
Views: 623
Posted By baki100
i have no idea if this can be done in php but try using an anonymous block and then test the input variables if not create a stored procedure in the database that accepts whatever you are trying to...
Forum: MySQL Oct 8th, 2009
Replies: 9
Views: 456
Posted By baki100
that's horribly inefficient using an inner select on the same table
Forum: MySQL Oct 8th, 2009
Replies: 9
Views: 456
Posted By baki100
SELECT *
FROM $tbl1_name
WHERE age BETWEEN '$from' AND '$to'
AND sex='$show_all'
Forum: MySQL Oct 7th, 2009
Replies: 1
Views: 318
Posted By baki100
in oracle i know the magic tables are the insert and delete when using and update so i guess it's those or maybe it's dual...hope i passed the interview
Forum: MySQL Oct 3rd, 2009
Replies: 1
Views: 320
Posted By baki100
no worries i found the error, i referenced foreign keys to tables that didn't exist yet
Forum: MySQL Oct 3rd, 2009
Replies: 1
Views: 320
Posted By baki100
can someone help me identify the syntax error with this code

CREATE TABLE IF NOT EXISTS Persons
( id_number VARCHAR(13) NOT NULL
, name VARCHAR(45) NOT NULL
, name_2 VARCHAR(45)...
Forum: Python Sep 30th, 2009
Replies: 4
Views: 537
Posted By baki100
you can use a dictionary but it won't be wise to use the surname as the key instead use the position number. for the itemvalues you can use a list and you can append new values later if needed so...
Forum: Python Sep 29th, 2009
Replies: 9
Views: 415
Posted By baki100
the reason it's coming up as match is that they are equal so i suggest declaring ind1, ind2 and making one 0 and the other 1

users = ('user1','user2','user3')
passw = ('pass1','pass2','pass3')...
Forum: Python Jul 16th, 2009
Replies: 2
Views: 1,053
Posted By baki100
have a read through this
http://groups.google.com/group/python-excel/browse_thread/thread/eb3475b5438c3e50
the guy convert xlsx to xls and from there you can convert the xls into csv using xlrd
Forum: Python Jul 15th, 2009
Replies: 3
Views: 232
Posted By baki100
send to me my email is bobepoundmax@yahoo.com please don't spam my mailbox and include comments please
Forum: Python Jul 15th, 2009
Replies: 11
Views: 565
Posted By baki100
try this:

infoToWrite = "Harry Potter: Teenage boy who has an owl"
myFile = open("characterlist.txt",'r+')
myFile.write(infoToWrite)
myFile.flush()


you can put a raw_input() line beneath...
Forum: Python Jul 14th, 2009
Replies: 7
Views: 706
Posted By baki100
it works but not what kiddo asked for, the application that he/she wants, wants to check for keyboard inactivity and if 3 seconds passed it prints the question 'Are you ready yet' again.
Forum: Python Jul 14th, 2009
Replies: 11
Views: 565
Posted By baki100
regarding that link i posted on the last poster suggests flushing the stream.
Forum: Python Jul 14th, 2009
Replies: 11
Views: 565
Posted By baki100
strange because it works in my compiler i used komodo 5.0 with python 2.6
have a look at this you might find something
http://bugs.python.org/issue3207#msg68773
maybe you should close the the file...
Forum: Python Jul 10th, 2009
Replies: 9
Views: 502
Posted By baki100
thanks for picking that up but you can also swap the split() & strip(). so you split to get the intended result and then strip whatever whitespaces is still left
Forum: Python Jul 10th, 2009
Replies: 9
Views: 502
Posted By baki100
if i understand your problem correctly i think is what you want,

for line in open('myfile.txt','rb'):
numbers = line.strip().split('=')[1]
print numbers
Showing results 1 to 40 of 44

 


About Us | Contact Us | Advertise | DaniWeb | Acceptable Use Policy | RSS Feed

©2003 - 2009 DaniWeb® LLC