SQL optimization

liunx

Guest
I have a question regarding sql. I have a inc connection file and this inc connection file is set to use intranet as database. The problem is few files use citylink database

So my sql I put
sql_my = "SELECT cus_id FROM citylink.cfa WHERE country = 'my'"

My question is should I put citylink and cfa before cus_id field in my sql above? This is because I already put citylink.cfa. I'm afraid if I put, there is no difference, thus redundant. Thanks for all replies.First off, don't use .INC files anywhere on your server. If you leave them like this then it makes it easier for hackers to get them off your site as the server itself does not try to process them and treats them like a text document. Rename them to .ASP. This way, if someone tries to view them via a web browser your server will process them like any other ASP page, and the hacker will just get a blank screen with no source.

Anyway, to the problem at hand.
You don't need to clarify which table fields are coming from unless you're using more than one table in your Select statement. So, no, you dont have to.Actually I use .asp as extension. That inc is just for my personal convention for shared code. Anyway, thanks for telling and the answers as well.
 
Top