External content based SharePoint list date/time information wrong
So, we have a SQL Server database that contains date/time type data.
When we look at the info in the database, the date and times appear to be in GMT, which is 5 hours before our time.
So, we set up views with a DATEADD calculation to compensate for the difference. When we use the view, the dates and times match our timezone info.
We then set up an external content to our view.
When the data is displayed in rows and columns, we see times that are 10 hours before GMT.
We had put in the dateadd calculations because when we had scripts that grabbed the data from SQL Server and put them into text files, the dates and times were all 5 hours off.
Is there code within the External data connectors (or SharePoint itself) which compensate for the time zones?
Thanks!
Hi Iwvirden,
When you create an External Content Type and External List using the SharePoint Designer, DateTime fields are normalized to UTC using the NormalizeDateTimesetting
associated with the TypeDescriptor for the DateTime field. This leads to the date field wrong in Business
Connectivity Services.
To fix this issue, you can change the normalization to use local time as follows:
<TypeDescriptor TypeName="System.DateTime"
Name="DueDate" DefaultDisplayName="Due Date">
<Interpretation>
<NormalizeDateTime LobDateTimeMode="Local" />
</Interpretation>
</TypeDescriptor>
Here is a similar thread for your reference:
Timestamp in Sharepoint external content type not matching value in SQL table
Here is a detailed article for your reference:
Why are my date fields wrong in Business Connectivity Services?
Best Regards
Zhengyu Guo
TechNet Community Support
Similar Messages
-
Build XML for Custom Nested Accordian (like Tree View Structure) for SharePoint List Data
Expected output in Xml:
<?xml version="1.0" encoding="utf-8" ?>
- <TopRoot>
- <Root id="1" Name="Department">
- <Type id="2" Name="IT">
- <SubType id="3" Name="Technology">
<SubSubType id="4" Name="Sharepoint" />
<SubSubType id="5" Name="ASP.NET" />
<SubSubType id="6" Name="HTML 5" />
</SubType>
</Type>
</Root>
</TopRoot>
List Details:
list details for storing category / sub category data and code to build tree structure for the same.
1.Create Custom List named “CategoryDetails”:
2.Create Column “Category Name” of type single line of text. Make it as required field and check Yes for Enforce Unique values.
3.Create column “Parent Category” of type lookup. under Additional Column Settings.
Get information dropdown, select “CategoryDetails”.
4.Choice column ["SRTypeName"] 1.Root,2.SRTYPE,3.SubSRTYPE, 4.SUBSUBSRTYPE
In this column dropdown, select “Category Name”:
Referance:
http://www.codeproject.com/Tips/627580/Build-Tree-View-Structure-for-SharePoint-List-Data -fine but don't want tree view just generate xml string
i just follwed above link it work perferfectly fine for building tree view but i don't want server control.
Expected Result:
My ultimate goal is to generate xml string like above format without building tree view.
I want to generate xml using web service and using xml i could convert into nested Tree View Accordian in html.
I developed some code but its not working to generate xml /string.
My modified Code:
public const string DYNAMIC_CAML_QUERY =
"<Where><IsNull><FieldRef Name='{0}' /></IsNull></Where>";
public const string DYNAMIC_CAML_QUERY_GET_CHILD_NODE =
"<Where><Eq><FieldRef Name='{0}' /><Value Type='LookupMulti'>{1}</Value></Eq></Where>";
protected void Page_Load(object sender, EventArgs e)
if (!Page.IsPostBack)
string TreeViewStr= BuildTree();
Literal1.Text = TreeViewStr;
StringBuilder sbRoot= new StringBuilder();
protected string BuildTree()
SPList TasksList;
SPQuery objSPQuery;
StringBuilder Query = new StringBuilder();
SPListItemCollection objItems;
string DisplayColumn = string.Empty;
string Title = string.Empty;
string[] valueArray = null;
try
using (SPSite site = new SPSite(SPContext.Current.Web.Url))
using (SPWeb web = site.OpenWeb())
TasksList = SPContext.Current.Web.Lists["Service"];
if (TasksList != null)
objSPQuery = new SPQuery();
Query.Append(String.Format(DYNAMIC_CAML_QUERY, "Parent_x0020_Service_x0020_Id"));
objSPQuery.Query = Query.ToString();
objItems = TasksList.GetItems(objSPQuery);
if (objItems != null && objItems.Count > 0)
foreach (SPListItem objItem in objItems)
DisplayColumn = Convert.ToString(objItem["Title"]);
Title = Convert.ToString(objItem["Title"]);
int rootId=objItem["ID"].ToString();
sbRoot.Append("<Root id="+rootId+"
Name="+Title+">");
string SRAndSUBSRTpe = CreateTree(Title, valueArray,
null, DisplayColumn, objItem["ID"].ToString());
sbRoot.Append(SRAndSUBSRTpe);
SRType.Clear();//make SRType Empty
strhtml.Clear();
SRType.Append("</Root>");
catch (Exception ex)
throw ex;
return SRType.ToString();
StringBuilder strhtml = new StringBuilder();
private string CreateTree(string RootNode, string[] valueArray,
List<SPListItem> objNodeCollection, string DisplayValue, string KeyValue)
try
strhtml.Appends(GetSRType(KeyValue, valueArray, objNodeCollection);
catch (Exception ex)
throw ex;
return strhtml;
StringBuilder SRType = new StringBuilder();
private string GetSRType(string RootNode,
string[] valueArray, List<SPListItem> objListItemColn)
SPQuery objSPQuery;
SPListItemCollection objItems = null;
List<SPListItem> objNodeListItems = new List<SPListItem>();
objSPQuery = new SPQuery();
string objNodeTitle = string.Empty;
string objLookupColumn = string.Empty;
StringBuilder Query = new StringBuilder();
SPList objTaskList;
SPField spField;
string objKeyColumn;
string SrTypeCategory;
try
objTaskList = SPContext.Current.Web.Lists["Service"];
objLookupColumn = "Parent_x0020_Service_x0020_Id";//objTreeViewControlField.ParentLookup;
Query.Append(String.Format
(DYNAMIC_CAML_QUERY_GET_CHILD_NODE, objLookupColumn, RootNode));
objSPQuery.Query = Query.ToString();
objItems = objTaskList.GetItems(objSPQuery);
foreach (SPListItem objItem in objItems)
objNodeListItems.Add(objItem);
if (objNodeListItems != null && objNodeListItems.Count > 0)
foreach (SPListItem objItem in objNodeListItems)
RootNode = Convert.ToString(objItem["Title"]);
objKeyColumn = Convert.ToString(objItem["ID"]);
objNodeTitle = Convert.ToString(objItem["Title"]);
SrTypeCategory= Convert.ToString(objItem["SRTypeName"]);
if(SrTypeCategory =="SRtYpe")
SRType.Append("<Type id="+objKeyColumn+" Name="+RootNode+ ">");
if (!String.IsNullOrEmpty(objNodeTitle))
SRType.Append(GetSRType(objKeyColumn, valueArray, objListItemColn));
if(SrTypeCategory =="SRSubTYpe")
SRType.Append("<SRSubType id="+objKeyColumn+" Name="+RootNode+
">");
if (!String.IsNullOrEmpty(objNodeTitle))
SRType.Append(GetSRType(objKeyColumn, valueArray, objListItemColn));
if(SrTypeCategory =="SubSubTYpe")
SRType.Append("<SubSubType id="+objKeyColumn+" Name="+RootNode +"
></SubSubType");
SRType.Append("</SubType>");
SRType.Append("</Type>");
catch (Exception ex)
throw ex;
return SRType.ToString();
// Call method again (recursion) to get the child itemsHi,
According to your post, my understanding is that you want to custom action for context menu in "Site Content and Structure" in SharePoint 2010.
In "SiteManager.aspx", SharePoint use MenuItemTemplate class which represent a control that creates an item in a drop-down menu.
For example, to create or delete the ECB menu for a list item in
"Site Content and Structure", we can follow the steps below:
To add the “My Like” menu, we can add the code below:
<SharePoint:MenuItemTemplate
UseShortId=false
id="OLListItemLike"
runat="server"
Text="My Like"
ImageUrl="/_layouts/images/DelItem.gif"
ClientOnClickNavigateUrl="https://www.google.com.hk/"
/>
To remove the “Delete” menu, we can comment the code below:
<SharePoint:MenuItemTemplate
UseShortId=false
id="OLListItemDelete"
runat="server"
Text="<%$Resources:cms,SmtDelete%>"
ImageUrl="/_layouts/images/DelItem.gif"
ClientOnClickScript="%SmtObjectDeleteScript%"
/>
The result is as below:
More information:
MenuItemTemplate Class (Microsoft.SharePoint.WebControls)
MenuItemTemplate.ClientOnClickScript property (Microsoft.SharePoint.WebControls)
Best Regards,
Linda Li
Linda Li
TechNet Community Support -
PowerPivot report data refresh error Data source as SharePoint list Data Feed
Hi All,
I am facing a problem on auto refresh, the report data source is SharePoint list Data Feed, I saved it my PC desktop when I set up auto fresh it fails then I moved the SharePoint list data feed "atomsvc" file to A SharePoint Data feed library then connected
to report started a manual refresh it was success, after next schedules it failed.
Error massage:
Errors in the high-level relational engine. The following exception occurred while the managed IDbConnection interface was being used:
The network path was not found. ;The network path was not found. The network path was not found. .
A connection could not be made to the data source with the DataSourceID of '82f49f39-45aa-4d61-a15c-90ebbc5656d',
Name of 'DataFeed testingreport'. An error occurred while processing the 'Testing Report' table. The operation has been cancelled.
Thank you very much !
erkindunyaIf you are using Claims Auth then this is a known limitation. Auto refresh only works under Classic Auth.
I trust that answers your question...
Thanks
C
http://www.cjvandyk.com/blog |
LinkedIn | Facebook |
Twitter | Quix Utilities for SharePoint |
Codeplex -
SSDT - Using a SharePoint list data feed as source - "column does not exist in the rowset" error
Hey guys!
So, I want to use a SharePoint list data to create a cube/tabular model, in order to make a complex analysis in PPS using MDX.
To create the tabular model, I'm using the SS Data Tools, and importing a feed from the respective SharePoint list (using the _vti_bin/listdata.svcextension and then selecting the list(s) I wanna to import).
Everything looks fine and smooth, I can select and preview the data in the table import wizard, but in the end, when importing, I always get this error IF the table has one or more row of data (if the table is empty, it's ok...) - the <...>
column doesn't exist in the rowset.
(Curiously, when I have the same procedure in PowerPivot for Excel, I have no problems, everything works fine. The problem is that then I get again errors if I try to create a tabular model on SSDT importing a PowerPivot file).
Here's the error:
Had you already tried this in SSDT? Are you experiencing the same trouble?
Best regards, and thanks in advance!
Jorge Mateus
Jorge MateusI noticed something else too.
I can't process Tabular Models on both SSDT and SSMS (2012), but I can process Tabular Models created on PowerPivot.
I tried to create a Data Feed connection on PowerPivot, and it was successfully created. However, if restoring the PowerPivot Tabular DB on my SSAS Tabular instance and processing (full) the model through SSMS, it won't work.
Is there anything different on PowerPivot and SSDT related with Partitioning or connections to the data sources?
Regards,
Jorge
Jorge Mateus
Update:
When trying to Restore a PowerPivot file on my SSAS Tabular Server and full process the model:
The operation failed because the source does not contain the requested column. You can fix this problem by updating the column mappings.
More Details:
The 'X' column does not exist in the rowset.
An error occurred while processing the partition 'X_81dabac5-c250-4a8c-8832-ad7fcedd35cb' in table 'X_81dabac5-c250-4a8c-8832-ad7fcedd35cb'.
The current operation was cancelled because another operation in the transaction failed.
X is the first column of the source table, no matter if I chose others on the PowerPivot table.
When trying to import data from a data feed using SSDT:
The 'X' column does not exist in the rowset.
An error occurred while processing the partition 'X_ee6be81f-2235-4113-b404-cfcb20647a38' in table 'X_ee6be81f-2235-4113-b404-cfcb20647a38'.
The current operation was cancelled because another operation in the transaction failed.
X is the first chosen column to import. -
Where does Apple collect their Date & Time Information?
I'm trying to isolate a problem for why the date and time for Unalaska and Dutch Harbor, AK when set automatically is on Hawaii Time when it should be on Alaska Time. The islands further west on the Aleutian Island Chain are on Hawaii Time, but not Unalaska Island. While in Unalaska, I have to set date & time on all my Mac devices to manual, and switch it back to automatic whenever I leave. As much as I travel, it is a nuisance having to switch back an forth between automatic and manual. This has been an ongoing problem for the past 2 or 3 years, and previously, it worked correctly.
I've noticed that some date/time websites have it wrong, but some have it correct. So, if I can find out where Apple collects their Date & Time information, I should be able to figure out whether it's an "Apple" problem or an "ISP" problem.Chris CA wrote:
OGELTHORPE wrote:
Terence Devlin wrote:
Wonder why Ford, General Motors and all those car manufacturers don't do this? Hmmm?
I thought that they put out recalls for stolen cars. Am I wrong on that?
Yes.
A vehicle recall is to fix issues that the manufacturer feels they need to do something about such as bad parts.
Or the Government felt they needed to do something about. -
How to access sharepoint List Data in Power Pivot model
Hi,
I have a sharepoint list and i want to access the list in power pivot workbook.
I tryed exporting the list as datafeed but iam that is missing under export.
Iam stuck pls help any other approach.?
Regards,
KrishnaaHello,
I have answered this question in this thread below:
http://social.technet.microsoft.com/Forums/office/en-US/92a04e1b-a5f7-4dbe-88e7-0a1064622641/sharepoint-list-access-in-power-pivot?forum=sqlkjpowerpointforsharepoint
Please go through the following aticles:
Using SharePoint List Data in PowerPivot:
http://msdn.microsoft.com/en-us/library/hh230322.aspx
Using a SharePoint List as a data source:
http://blogs.technet.com/b/excel_services__powerpivot_for_sharepoint_support_blog/archive/2013/07/11/excel-services-using-a-sharepoint-list-as-a-data-source.aspx
Regards,
Elvis Long
TechNet Community Support -
Dynamic chart using SharePoint list data
Is it possible to create dynamic chart from SharePoint List data using OOB.
I have column Status [ choice - Pending , Submitted, Resolved ] . I want to genrate graph[Pie or Bar] show number of items in each status
V JeanThanks Lakshmanan,
But in my environment - chart webpart is not available [ restricted].
Have tried below using script.. Hope might help for other
https://www.nothingbutsharepoint.com/sites/eusp/Pages/finally-dynamic-charting-in-wss-no-code-required.aspx
V Jean -
Calendar now splits my entries into 2 separate entries. 1 entry lists date/time/name. The second entry lists notes and alerts. I can delete the date/time one, but not the alert entry. That means I will get all the alerts even if I deleted the original entry. It shows up as two separate entries for each one entry. This happened after the Yosemite install.
Calendar now splits my entries into 2 separate entries. 1 entry lists date/time/name. The second entry lists notes and alerts. I can delete the date/time one, but not the alert entry. That means I will get all the alerts even if I deleted the original entry. It shows up as two separate entries for each one entry. This happened after the Yosemite install.
-
Export SharePoint List data to SQL Server 2005 Database
Hello Everybody,
I am presently working on a project which handles much larger amount of data. The architecture of the application demands extracting records from the SharePoint (WSS 3.0) and insert into a SQL Server 2005 database. I need to run this job as daily basis. I am thinking of using SSIS (SQL Server Integration Service) for this purpose. But I am new to this technology and I'd like to know how effective this idea to do the job.
I'd also like to know more about SharePoint's ability to handle huge amount of data when it comes to Reporting.
thank you,
ArunFor Reporting Services, There are web parts available which can be used to render a reporting service report in sharepoint. I have also used a reporting service report directly using Page Viewer Web Part so displaying a reporting services report in sharepoint is very simple task. Important part is to transfer data from Sharepoint list to SQL 2005. so if you want to use SSIS package and there is only one or two list then approach is to write a simple query based on your list id and extract information from sharepoint content database from UserData table, since it is a read only operation so it can work this way. Another way to do it is to write a Sharepoint Timer JOB which runs on a defined schedule and will read your list values and will transfer to your SQL 2005, Another way could be to write your custom web service and write code to transfer from list to SQL 2005. Custom code you will write inside timer or web service will be same code so it is just a different shell you can say. in case of web service, use it in some other application as a regular web service.
Let me know if you need further help, You did not mention how many list you have?
Regards,
BizWorld. -
External content type error: Business Data Connectivity object not found.
Hello
I have to change the external database (external system) for an external content type. The database view on the new database is exactly the same as on the old database.
After changing the external system of the external content type, this happens:
When I try to add a new item to the list, I get this error under the external data field:
"Business Data Connectivity object not found. Administrators, see the server log for more information."
Also, when I try to update the external data field, it is not possible because the buttons are grey.
When I add a new external data field to the same list, I can use the external content type. For some reason the current external data field doesn't update.
Any ideas?
Any help would be much appreciated!Have you implemented both ‘Read List’ & ‘Read Item’ operations in your ECT?
This may be helpful -
https://sharepointcreations.wordpress.com/2014/03/13/business-data-connectivity-object-not-found/
Thanks
Ganesh Jat [My Blog |
LinkedIn | Twitter ]
Please click 'Mark As Answer' if a post solves your problem or 'Vote As Helpful' if it was useful. -
Unpivot SharePoint list data in SSRS
I need to unpivot data from a sharepoint list to support a report.
the data looks like this
Policy comissiona comissionb comissionc
a 1 2 3
b 4 5 6
i want the result
as
policy comission total
a comission a 1
a comissionb 2
a comissionc 3
b comission a 4
bcomissionb 5
b comissionc 6
ThanksHi Vision2040,
Based on my research, it’s not supported that making Unpivot data from a sharepoint list currently.In general, we can use PIVOT and UNPIVOT relational operators to change a table-valued expression into another table.
For the details, please refer to the link:
http://technet.microsoft.com/en-us/library/ms177410(v=sql.105).aspx
Regards,
Heidi Duan
Heidi Duan
TechNet Community Support -
Excel Services with SharePoint List Data in SharePoint 2013 - Chart is not refreshing automatically
Hi Everyone,
This is My req: I m going to display pie chart and Bar chart in share point 2013.
Steps I have follwed:
1. Export the list to excel.
2.Using the Power Pivot table I have done the chart.
3. Uploaded into document Library.
4. Added into the web part.
Chart are displaying. But When ever user added the data into the list chart is refreshing.
Is there any option to refresh the data in chart? Waiting for valuable replies.
Regards, Manoj PrabakarSharePoint lists as data sources in Excel Services is not supported.That's the reason refreshing is not working. There are some work around you can use -
Export as Data Feed - Export your SharePoint list as Data Feed , use this data feed to a PowerPivot for Excel workbook and publish this PowerPivot using Excel Services.
User-defined functions - write UDF in C# and extend the Excel Services functionality to work with SharePoint lists.
https://msdn.microsoft.com/library/bb267252(office.12).aspx#Office2007ExcelServicesUnlimited_SharePointLists
Web Services API -
The Web Services API can be used to push data from a database and then refresh the data in a SharePoint Server list by using Excel Services.
JavaScript Object Model - The JavaScript Object Model for Excel Services in Microsoft SharePoint Server 2010 provides many solutions for Excel Services.
More details -
https://technet.microsoft.com/en-us/library/gg576960.aspx
Thanks
Ganesh Jat [My Blog |
LinkedIn | Twitter ]
Please click 'Mark As Answer' if a post solves your problem or 'Vote As Helpful' if it was useful. -
How to retrieve sharepoint list data and show it on excel-addin using C#
Hi,
we have a sharepoint list where all students are present. we wanted to get the data from the list and show it via excel addin (VSTO) (something like save,retrieve buutons) . we have some more business logic which need to be performed before the data is retrieved
. once data is shown on excel , user modifies it and update/save the record back to sharepoint.
can you please give some samples and suggest any links to start with development.
Thanks
chaituHi chaituatp,
For this requirement, I would suggest you to get familiar with how to create VSTO applications, and how SharePoint object model works. Here are some sample code about this:
How to: Retrieve List Items using JavaScript:
http://msdn.microsoft.com/en-us/library/hh185007(v=office.14).aspx
http://msdn.microsoft.com/en-us/library/office/ee534956(v=office.14).aspx
VSTO application show data in datagridview:
http://stackoverflow.com/questions/16926275/simple-example-of-vsto-excel-using-a-worksheet-as-a-datasource
Thanks,
Qiao
Forum Support
Please remember to mark the replies as answers if they help and unmark them if they provide no help. If you have feedback for TechNet Subscriber Support, contact
[email protected]
Qiao Wei
TechNet Community Support -
Unable to connect to SharePoint list data from PowerPivot in Excel
Hi,
I have the PowerPivot excel add-in installed and I can connect successfully to SQL data. I have two SharePoint farms - Farm 1 and Farm 2.
I am able to connect PowerPivot to SharePoint lists in multiple web applications in Farm 1 by using the ListData.svc.
e.g. https://farm1/_vti_bin/ListData.svc/Tasks
In Farm 2 I am unable to connect to SharePoint data. I have tried multiple web applications on Farm 2 and can't connect. I receive the following error. I am able to browse to the address in Internet Explorer and see a feed.
Has anyone else had this error?
Thanks in advance,
Mark
Error Message:
============================
Cannot connect to the specified feed. Verify the connection and try again. Reason: The underlying connection was closed: An unexpected error occurred on a receive..
============================
Call Stack:
============================
at Microsoft.AnalysisServices.Modeler.DataImportWizard.DataSourceBasic.UpdateDataFeedParameters(ConnectionStringBuilder connBuilder, IDataSource dataSource, Boolean checkFeedValid)
at Microsoft.AnalysisServices.Modeler.DataImportWizard.DataSourceBasic.GetCurrentConnectionString(Boolean checkFeedValid)
at Microsoft.AnalysisServices.Modeler.DataImportWizard.DataSourceBasic.ClickTestConnection(Object progressControl)
============================Hi Millard1,
From your descripton, it seems you want to use SharePoint list as a data souce. If so, you should export the SharePoint as data feed in your SharePoint site, and then create a new PowerPivot table that contains the list. Here are some articles for your reference,
please see:
Use Data Feeds (PowerPivot for SharePoint):
http://technet.microsoft.com/en-us/library/ee210625.aspx#sharepointlist
Using a SharePoint list as a data source:
http://powerpivotgeek.com/2010/10/28/using-a-sharepoint-list-as-a-data-source/
Regards,
Bin Long
TechNet Community Support -
Filtering sharepoint list data using report parameters
We are using xml to pull data from a custom sharepoint list into sql 2005. We have set a parameter that allows the user to filter the data by surname, however when the user tries to filter the list the drop down box brings up a list of every record, so there are duplicate entries for each surname.
Is there a way of filtering this so that there is only one instance of the users surname instead of it showing all the records?
Any help would be much appreciated.Hi,
Please see the below url
https://social.msdn.microsoft.com/Forums/sqlserver/en-US/c43f25ab-aa3c-4586-85a1-1b89c3b21b12/how-to-filter-a-sharepoint-list-with-report-parameters?forum=sqlreportingservices
Solution is define here.
Hasan Jamal Siddiqui(MCTS,MCPD,ITIL@V3),Sharepoint and EPM Consultant,TCS
|
| Twitter
Maybe you are looking for
-
Web Clipping portlet causing report from SQL Query to fail
I have a master page that contains: 1. web clipping portlets (from external sites) 2. customizable reports built from Portal Providers also added to the page as portlets Problem: When the web clipping portlets were added to the page, the reports now
-
PC Suite Upgrade : Phone (N70) not supported
Hi Just upgraded to latest version of PC Suite and have hit problems. Prior to upgrade phone and PC were connecting fine with no problems. Now when establishing connection between phone and PC receive following message :'PC Suite does not support the
-
Simple wav problem! PLZZZ help!!!!!
Hi, I have a problem with playin waving files. In my application, i want a sound to be played wen a popup box appears. Here is my code: AudioClip beep = null; try File audioFile = new File("Sounds\\beep.wav"); beep = Applet.newAudioClip(audioFile.toU
-
I had trouble recieving a movie download. Please refund my money.
-
FCP X 16:9 standard def project is squashed in iDVD?
This request for info is for a friend. He shot a 16:9 standard definition project on DV TAPE and edited it in FCP X using the Anamorphic DV preset. When exported as a Master File and put into iDVD it plays squashed as 4:3 I believe this is connected