Questions tagged [sqlserver]

The tag has no usage guidance.

Filter by
Sorted by
Tagged with
0
votes
1answer
44 views

Multiple SELECT in subquery

In Marketing Cloud, we would like to check for the existence of records from one table in multiple other tables based on the unique identifier - Customer_ID. However, I'm not sure whether I can ...
0
votes
1answer
80 views

Get all records inside a given date

I need to get all the records that are inside a given date. What I have now is giving me only one of them randomly every time I run my query. Any suggestions on how to fix that? SELECT table1.Number ...
0
votes
1answer
21 views

SSIS with Salesforce [closed]

I have a requirement where in we need to push data from sql server to Salesforce on daily basis. Can anybody suggest me the best possible way to do the same ? Also After googling things, it seems ...
0
votes
1answer
164 views

Date format in SQL query

We need a specific format date to personalize our emails, for example, the US date format is MM/DD/YYYY HH:MM:SS and we need to display DD/MM/YYYY. Is it possible to change the date format directly ...
2
votes
1answer
50 views

How can I setup a scheduled sync from a SQL Server database to Salesforce Big Objects?

What is the best way to have a daily scheduled insert/update of a SQL Table into Salesforce Big Objects? We currently have a C# adapter to update Salesforce standard object records with SQL database ...
1
vote
2answers
41 views

Importing data from multiple external tables to a single object

I am trying to use a production SQL Server database to send relevant data into Salesforce to generate reports. Some of the data I would like to use however is not consolidated into a single database ...
2
votes
1answer
166 views

Date and Time function not usable anymore

Good day, I use in Automation Studio, an SQL query using functions like dateAdd() and Datediff(). Since yesterday, this activity is errored with this message : " An error occured while checking the ...
0
votes
1answer
601 views

Updating a Salesforce object directly from a SQL server Stored Procedure [closed]

I want to update a Salesforce Object from a Stored Procedure inside Microsoft SQL Server. Is this possible? I have use case that will get data from 'X' database .From 'X' db SQL server will get ...
0
votes
1answer
803 views

Salesforce DB connect with SQL Management Studio

I'm trying to connect SQL Server Management Studio to Salesforce so I can see tables and columns but unable to connect. Do I need any ADO.net connector or Salesforce plugin for this to work? Do I need ...
2
votes
1answer
79 views

Transferring data between DE 1 and DE 2 when record not present in DE 3

I have 3 data extensions: Master, Local and additional, supporting one which essentially functions as historical Storage of all the records that ever landed in Local. So the data flows like this ...
0
votes
1answer
331 views

Exact Target SQL comma separated values within a field

We are having a field called - ‘VisitOverdueMailingList__c’ on the Account object populated with comma separated values. The field contains data in the following format (only for certain Accounts that ...
0
votes
3answers
1k views

Query Failing: Time Out

I have a query that has started failing due to the fact that it has over 400M rows. Although there are joins and fuzzy matching (LIKE '%XXXX%') it is still failing. Using NO LOCK too I have used ...
0
votes
1answer
726 views

Using CASE to update a field

I'm getting an error on my case statement in SFMC. Is it a simple mistake of syntax? SELECT *, CASE WHEN status <> 'active' THEN 'active' ELSE status END AS status FROM [sample table] WHERE ...
1
vote
1answer
298 views

Error with Duplicate Primary key in Marketing Cloud SQL

We have multiple newsletters that generate leads for marketing emails. I'm trying to automate the process of consolidating those leads into one master data extension after they have been on a ...
0
votes
1answer
71 views

How to capture Data Loader error when called from Shell script via SSIS package?

Salesforce Gurus: Thank you in advance for any insights you may have. For years now I have been extracting data from a custom Salesforce object named Branches__c using the following method... ...
1
vote
0answers
35 views

query gets wildly varied results on sql server vs sf of same dataset

the data is 1:1 with SF on the sql server with same named columns, yet... SELECT ID,TIER__C FROM [salesforce_stage].[dbo].[SFDC_ACCOUNT] where TIER__C NOT IN ('C1', 'E1', 'E2', 'E3', 'E4', '...
0
votes
1answer
359 views

Query Error - cannot convert nvarchar

I am trying to return details associated with a certain email address . I am using the query below: select emailaddress ,subscriberkey ,record_type_name__c from mastersubscriberde where ...
2
votes
1answer
568 views

Store Data from Salesforce Marketing Cloud to my local SQL database server

Am new to using Marketing Cloud. I want to know if there is a possibility of storing the data from Marketing cloud campaigns and Subscriber activity, Conversion tracking data to my local SQL server? ...
1
vote
1answer
70 views

Marketing Cloud - Replacing Multiple hardcoded values in JOINS with values from Parameter Table

Salesforce Marketing Cloud query activities do not allow variables or temporary tables according to the "SQL Support" section of this official documentation (http://help.marketingcloud.com/en/...
0
votes
0answers
470 views

SF Marketing Cloud - Query Variable Table for value used in SQL function

Salesforce Marketing Cloud queries do not allow variables or temporary tables according to the "SQL Support" section of this official documentation (http://help.marketingcloud.com/en/documentation/...
0
votes
1answer
96 views

Query not returning values

I have the written the query below to return two values. I have also check the DE to ensure that it has the correct data types. Unfornately, the query is not returning any values: SELECT M....
0
votes
0answers
177 views

SQL server table not locating the respective Record ID

My SQL server administrator could establish a connection with our salesforce sandbox instance and could bulk insert brand new records. However, he couldn't update the existing records as the record ID ...
0
votes
1answer
54 views

How can I setup an integration between Salesforce CRM and Microsoft SQL Server using PHPToolKit?

How can I setup an integration between Salesforce CRM and Microsoft SQL Server using PHPToolKit? We dont want to use any ETL toolkit to integrate this two environments. We would like to pull the SQL ...
0
votes
1answer
283 views

SFMC Query : Count Not Working

I am trying to count to number of subscribers have made a transaction. I am using the code below: SELECT M.Id SubsriberKey ,COUNT (Transaction_ID__c) OVER (PARTITION BY M.Id) AS ...
2
votes
1answer
365 views

How do i resolve 'Error while processing square brackets' when there are no square brackets in the query?

this is the query: select opp.* from ( select opp.*, row_number() over (partition by opp.contact_email_address order by opp.status_date desc) as row_number from opportunity_data opp ...
2
votes
1answer
38 views

Save error: Constructor not defined: [Sample11.EventData].<Constructor>(Id, Datetime, Datetime, String)

I'm trying to expose user related events using REST API but I get the error at line 33. Why? Error Line: EventData eveData = new EventData(eve.Id,eve.StartDateTime,eve.EndDateTime,eve.subject); ...
1
vote
1answer
454 views

Creating Data Extensions by running queries [closed]

Is it possible to create data extensions by running a query with the CREATE TABLE function?
0
votes
1answer
967 views

Square Brackets sql query error

I am receiving an error: The query syntax is invalid Error while processing square brackets I have tried to run it with and without brackets and still receive the same error. Please also note ...
1
vote
1answer
749 views

Exacttarget SQL Query Help: Find all Subscribers that opened at least 2 emails

I am trying to write a query to identify all subscribers that opened at least 2 emails in the last 6 months. I will pull from a data extension called "Clients" and look for all opens in the "_open" ...
2
votes
2answers
2k views

Query Activity Failing

I have set up a data extension to capture a query and return it's results. In order to track the query, I am running it in automation studio. However, the query keeps failing. I have checked that the ...
0
votes
1answer
40 views

Saleforce list to include data from SQL Server [closed]

I need to create a list in Salesforce that include leads from Lead.com, Radius AND leads from my company’s own list in SQL server. It seems simple enough to create a list in SF that includes leads ...
0
votes
1answer
72 views

SFMC query speed

I'm automating a bunch of queries and sends in SFMC and am curious about how long SQL queries take to run. Is there a log where I can see the time taken for a query to finish?
0
votes
1answer
278 views

Open rate by domain over time - SQL

I'm trying to figure out open rate over time based on domain however, it seems to error or timeout every time I run it. I've limited it to just gmail, yahoo, and AOL for now. SELECT o.domain , s....
0
votes
1answer
719 views

SFMC Filter Activity - Date + -

When creating a filter in the Marketing Cloud, say when filtering a Data Extension, you can base any of the statements in the filter off of a date field. The question I have relates to when using the ...
1
vote
1answer
80 views

Pushing data from MSSQL into Salesforce

Are there any best practices or recommendations for syncing licence data from our MSSQL database to Salesforce custom objects which are child objects of Accounts? As a SaaS app, customers can sign up ...
1
vote
1answer
71 views

Possible to replicate a scheduling tool built in Microsoft Access in SFMC?

My company has recently started using Salesforce Marketing Cloud. We are a team who send marketing emails, and are soon retiring our old email software. At the moment, the email schedule is kept ...
0
votes
1answer
161 views

Oracle SQL to SFMC Date Issue

Running a query to send email subscribers a +X day email. FIRST_PROMO_SUBSCRIBE_DATE is coming from Oracle which they say is not a compatible format with Salesforce SQL so I have; select * from ...
3
votes
1answer
225 views

Marketing Cloud SQL Injection?

I had a question come up that seemed a bit ridiculous at first, but has got me wondering. Is it possible to run any sort of script or SQL injection equivalency on forms that are configured to direct ...
0
votes
1answer
83 views

DE Update All Rows Based on Value of Last Row of another DE

I have two Data Extensions - BlogPost and BlogList BlogPost has three columns pubdate | title | sent --------------------------- 3/12/2016 | XYZ | True 3/15/2016 | ABC | False BlogList has ...
4
votes
0answers
101 views

Is This Project Possible?

I'm setting up a Wordpress site for a new customer. They have moved their customer database from a plesk environment to a salesforce database, 13 records per row including address, id, phone number, ...
3
votes
1answer
924 views

Hide iframe url

I am using a visualforce page and adding an apex tag: <apex:page standardController="account"> <apex:iframe src="a.com/embed/preview/f?theme=dark fullscreen" width="100%" height="800px" ...
1
vote
1answer
84 views

How to join two selects

I have these queries, select ownerId from account select firstname from user How can I join them? OR How can I get the owner name from account table? Thanks in advance.
1
vote
1answer
135 views

READ access to Salesforce Schema through SQL Management Studio or some other IDE

I'm having problems writing SOQL statements to include a number of different objects and creating temporary fields for adhoc querying. I'm able to do this with a Standard SQL Server database. I'm ...
0
votes
3answers
2k views

Exact Target SQL find two values within a string

We have a value stored in a string in a table and we need to extract 2 values from it into 2 new fields. The field name is linkname and it contains a value like 'VALUE1-VALUE2-52'. We need to pull ...
1
vote
1answer
383 views

SQL Error: Old style JOIN (ANSI JOINs) syntax is not allowed [closed]

I have the following SQL query activity in Marketing Cloud, which is producing an error: Old style JOIN (ANSI JOINs) syntax is not allowed. SELECT CASE SurveyResponse WHEN '' THEN ...
0
votes
1answer
390 views

Error when trying to query _Job system data view

I'm trying to run a query to a data extension to grab info in the last 30 days from the _Job data view. I continue to get the error: "_Job is not a known data extension or system dat view." ...
3
votes
3answers
926 views

How to query distinct triggered event dates?

I've tried 50 different variations and still get the same result. I want to query the _Open table on ET's servers and return all unique events for a subscriber. When I go into the triggered event ...
0
votes
1answer
338 views

SFMC Query help - transpose data in SQL Server

We have the following table which contains data which scores a customer for a category. We want to transpose that into another table so it says which category the customer is most likely to be in. ...
2
votes
1answer
234 views

Unable to access LastViewedDate on Account object SQL [duplicate]

I am trying to get the list of last 10 accounts viewed. The code seems to be working in sandbox and workbench but when I try deploying it in production, I get the error: No such column 'LastViewedDate'...
1
vote
1answer
287 views

How to fetch the data form SQL Server into the Visual force Page in salesforce? [closed]

I want to fetch the data from sql server into salesforce visual force page.Is there any specific approach for this?Please help me with this.