Sql Gives 78 Wich I Don't Like

Apr 10, 2008

Hi,

I've the sql code below wich give interesttarget 78 as a result wch I shouldn't. I think it has something to do with the'(' and  ')' .

SELECT Top 5 *

  FROM TestnetCampaign a, TestnetAds b

WHERE a.campaignid = b.campaignid

     AND b.sizeid = 21

     AND (

                 a.interesttarget LIKE '10,%'

           OR a.interesttarget LIKE '%,10,%'

           OR a.interesttarget LIKE '%,10'

             )

    AND (

                 a.interesttarget NOT LIKE '78,%'

           OR a.interesttarget NOT LIKE '%,78,%'

           OR a.interesttarget NOT LIKE '%,78'

            )

ORDER BY a.ecpc DESC

Any suggestions?

Thanks!

Roel

View 2 Replies


ADVERTISEMENT

Wich Datatype?

May 5, 2006

Hi Group,

Wich datatype can I best use for a number with several decimals (can be anything between 1 and e.g.10)

If the number has 10 decimals the customer needs the EXACT numbers. They couldn't explain why....

TIA

Regards,

Sander

View 7 Replies View Related

Wich JOIN To Use For ..

May 20, 2008

Hello, if i have

TABLE ITEMS
ItID(PK) | ItName
---------------------------------------------------------------
1 Bike
2 Car
3 Boat

TABLE DET
ItID(PK)(FK of ItID) | Detail
---------------------------------------------------------------
1 Mountain
1 With Suspension
2 5 Airbag
2 3500 c.c.
2 215cv.
3 with cabinet

And i want a table result like
ItId ItName Detail
---------------------------------------------------------------
1 Bike Mountain
2 Car 5 Airbar
3 Boat with cabinet

WHAT "JOIN" I NEED TO USE OR WHAT QUERY I NEED TO WRITE. CAN ANYONE WRITE ME THE QUERY, that as i show in example, will return only the first Detail for each Item

View 13 Replies View Related

Wich Collation For Euro Character

Mar 14, 2008

Hi,
 Wich collation should I use for the right display of the euro character? I now get a '?'.
Thanks!
Roel

View 1 Replies View Related

Express Edition 2005 Wich The Limits ?

Sep 22, 2006

Hi, i'd like to try Express2005 but before i'd like to know
wich are the limit vs Sql Server.
I had seek in Microsoft's site but i haven't found it
anyone kwon it ?
Thank's for the answer

Daniele Pinai
(Italy)

View 2 Replies View Related

Wich One Is More Efficient ? Datafile Or Attached On Server ?

May 8, 2008

Hello friends !
Wich one is more efficient way to use a sql mdf file in Sqlexpress ?
attaching a mdf file on sqlexpress ( and use initialcatalog in connection string ) or use AttachDbFilename on connection string directly ?
Is there any difference in performance and speed ?
Thanks a lot

View 1 Replies View Related

Wich Is Faster? In Relation To These Two Business Object Scenarios

Jun 27, 2006

I kow for a solid comparison between using datareaders and datasets I will have to perform that myself.  But for now I will be utilizing datasets...
What I am doing is currently utilizing assemblies to create my datasets ahead of time.  I will eventually compile them as dlls.  I'm just utilizing assemblies during my building/testing fase.
My questions is:
Is it faster to completely build the datasets and all needed connections inside the assemblies/dlls and fill them?  Or to build the datasets and connections as a sub procedure that can be accessed and then fill them as each required set of data is needed?
I ask because I will be having many different data connections and so I'm not sure if it's faster to explicitly build/fill almost each and every one and have them compiled at runtime ready to be accessed, or to file them when called from a sub etc...?
As I take it, the server should track and monitor which are used the most, and cache them, so as to operate faster.  I wonder if it will still do this if the datasets aren't pre-filled?

View 2 Replies View Related

Create A Data Flow In SSIS Wich Updates Som Rows.

Aug 14, 2006

Hi,

I have a table customer wich has the columns phone_number(char type) and ok_to_call(bit type). There are already data in the table and the column ok_to_call only contains the value false for every row.

Now i want to update the latter column. I have a text file with a list of phone numbers and i want that all the rows in the Customer table(phone_number column)that matches the number in the text file to update ok_to_call to true.

This is to be done in SSIS(Integration Services). I'm new at this and i've looked around that tool but is a lot of items, packages and stuff so i dont know where to begin.

Would appreciate help on how to solve this issue in SSIS. What controlflow/Data flows to use,wich items and packages to use, how to configure and how to link together?

Regards
/Tomas

View 3 Replies View Related

Quale Tipo Di Indice Sulla Tabella? Wich Kind Of Index On Table..??

Jul 20, 2005

ciao a tutti...ci risono...devo migliorare delle performance di accesso ad una tabella...la tabella non ha indice primario, ne altri indici...sulla tabella ci accedo con select di questo tipo..select @ExistInOAG = count(*)FROM caprs05dev.dbo.OAGWHERE Air_Carrier = @Aircarrier andcast(ltrim(rtrim(Flt_nbr)) as int) =cast(ltrim(rtrim(@ComFltNbr)) as int) andAipt_Dpt = @AIPTDep andAipt_Des = @AIPTDst andDT_FLIGHT = @Date_Rif andconvert(varchar, STD, 102) = convert(varchar, @STD,102) andconvert(varchar, STA, 102) = convert(varchar, @STA,102)ho provato a creare diversi tipi di indici, ma le performance migliorile ottengo se lascio stare tutto come era senza nessun'indice!!!! visembra possibile???le prove che ho fatto sono queste...inserire un indice tipo Primary con i campiFlt_nbr,Aipt_Dpt,Aipt_Des,STD,STAcreate Unique, tipo Index, con Ignore duplicate key...create as clustered checcato e fill factor 100%... ci accedopraticamente solo in select nel file...avete consigli per migliorare le performance di accesso allatabella????grazie.. stefano!!!

View 2 Replies View Related







Copyrights 2005-15 www.BigResource.com, All rights reserved