All the databases are stored in a remote server where I need to access remotely.
I need to access to Analytic db from my code behind file to get most viewed page.
So, I tried with something like this:
SqlConnection thisConnection = new SqlConnection("Data Source=xxx.xxx.xxx.xxx;database=xxxx ;User id=xxxx;Password=xxxx;");
But an exception was thrown (Login in failed ... )
And I have found few guides, but not really understand how it is used.
Guide 1: using Creating LINQ to SQL Classes (O/R Designer) as mentioned in http://learnsitecore.cmsuniverse.net/en/Developers/Articles/2009/09/mostviewedList.aspx
can anyone tell me or guide me what should I do? I have totally 0 idea on doing this.
Guide 2: using configuration manager (I haven't tried this yet)
string connectionString = ConfigurationManager.ConnectionStrings["ApplicationServices"].ConnectionString;
using(SqlConnection SqlConnection = new SqlConnection(connectionString));
Which version of Sitecore are you using? Are you using OMS or DMS? The article you linked to is for querying OMS, in Sitecore 6.5/DMS you should just be querying via the Sitecore.Analytics API and therefore should need a sql connection reference.
How to get item page views using sitecore 6.5 Analytics API
Jim mentions in this answer that he ended up writing his own calls. May be he might be a source of more information.
Moreover I am not aware that what exactly is your requirement but have a quick look at this page and see if this code offers what your are after.
Hope this helps.
Related
I was trying to install the default Storefront site(powered by Commerce Server). It looks good at the moment, I managed to rebuild all indexes and publish the content. However, I can't reach product detail page - I receive an exception.
Example here.
I had faced with the similar issue when I tried to click on any catalog category.
The log-file contains the same error message without any details. Could you please suggest something to fix this issue?
P.S. After the finishing the installation I didn't have any products on the site. I fixed that issue:
selected the default Adventure Works catalog in the Sitecore tree(using content manager).
Filled in field CategoryDatasource(with the path to categories)
I think it might cause the error which I described above.
Thank you in advance for the help.
You have to set the catalog for the site via a home node property.
I have a Django site and a local install of Alfresco (community edition). One of my model contains a file reference which maps to a document in Alfresco. The view should have a field that spawns a file browser that can access the repository structure within Alfresco so that the user can pick whichever file they want at whichever version.
I looked at the CMSIlib module and it seems to be providing all the interaction I need for the back end code. Although downloading a document seems clunky.
There are lots of Django file browsers but none seem to interface with CMSIlib.
Do I have to code my own or have I missed something?
The version is Alfresco Community v5.0.0 (d r99759-b2) schema 8022 Spring Surf and Spring WebScripts - v5.0.0.
To be honest, I am not a python guy ! But I heard over the official #alfresco IRC channel that cmislib is not so much of an active project, and questions about it only bump once in a while .... The RESTful api however may be considered as a good alternative in your use case:
To access alfresco content using the RESTful api, you should be querying this webscript: /alfresco/d/<d|a>/<workspace>/<store>/<nodeId>/<filename>
where :
d and a refer to direct / attached mode
<workspace>, <store> and <nodeId> reference your content nodeRef
<filename> a file name of your choice
So you should be making a GET Request an a URL that looks something like this http://<host>:<port>/alfresco/d/d/workspace/SpacesStore/8444ad61-4734-40e3-b2d4-b8b1c81347fd/myFile.ext
Note : Depending on the permission set on your node, you might need to attach an alf_ticket to the URL for an authenticated alfresco user. Please check this for further insights.
UPDATE 1:
If you have a problem identifying your file nodeRef, then you can setup a repo webscript implementing your custom logic (browsing some folder / searching for a document by name or metadata ....)
If your are not familiar with webscript development check Jeff Pott's tutorial on the subject
UPDATE 2:
To get started with your webscript development check out Alfresco docs/wiki!
Check this wiki page to learn how to retrieve children for a given node !
Or check this wiki page to learn how to develop webscripts implementing your custom business logic.
If you do not have anything against the YUI javascript library (that is no longer actively maintained), you can integrate the object-finder already available in Alfresco Share. The library is in
share/components/object-finder/object-finder.js
You will need to modify it a bit given that you are not inside Share.
To be totally honest, I do not know if it is feasible because it has other dependencies but being a browser site library, in theory can be integrated everywhere.
I've set up a local Sitecore environment with all sql and mongodb db's working.
Except i do not get any data in the experience profile (contacts)
I see that tracking_contact db is empty in mongo and also the analytics index folder is empty.
Other functionalities like experience analytics work fine.
Are there any extra configurations necessary?
The Experience Profile runs on the Analytics index. If there is no index, there will be no data shown.
Try to rebuild the index if it's not there.
There is an admin tool for rebuilding the reporting db & analytics index: /sitecore/admin/RebuildReportingDB.aspx
When you run the tool you must setup a secondary reporting db first.
Just attach another empty analtyics database to your local SQL and name it something like analytics_secondary and configure its connectionstring.
Then rebuild the reporting db and after that data should appear in your Experience Profile.
The index should be constantly refreshed by the aggregation framework (i.e. you should not need to rebuild) so if that is not happening, something is wrong in your configuration.
When working with xDB you'll need to identify a user to get it to appear in the experience profile section otherwise they will be anonymous.
Try using this code here to create a contact:
https://github.com/ianjohngraham/CoreBlimey.Utils/tree/master/CoreBlimey.Utils/xDB%20Contact%20Creator
And then call the end session by using the button.
If everything is setup correctly then the contact you created will appear in MongoDB and in Experience Profile.
If you are still not getting any data then you could try these things:
Ensure you have the <sc:VisitorIdentification runat="server" /> control for asp web forms layout
the #Html.Sitecore().VisitorIdentification() control for MVC layout
Make sure you disable robot detection by changing this setting <setting name="Analytics.AutoDetectBots" />
Charley,
I also had the similar problem in past, so what I found was, it was not working in my local, but when i put it stage server it shows data to me. So same may apply to you also.
Also without "#Html.Sitecore().VisitorIdentification()" in your Layout tracking is not possible.
Hope this will help you.
cheers!!
I want to do simple CRUD operations for simple ColdFusion applications. I have simple guidelines but not deep guidance for that and it looks a little tricky for me. Anyone there who can provide a simple and detailed solution for that. Actually I have created database and tables on http://localhost/phpmyadmin/ but how can I use the database and tables in CF-Builder applications, I don't know that. If I'm missing anything else, please mention it.
Thanks,
Before someone closes this, check out this intro to CFBuilder that shows you how to connect to a database:
http://refcardz.dzone.com/refcardz/getting-started-adobe
Then go through the lessons at http://www.learncfinaweek.com/. If you've done CRUD apps in any other language, you just have to learn the CF syntax for doing the same processes.
In CFBuilder 2 and 3, there is a view, "RDS Dataview" that shows the hosts (ColdFusion servers) you've provided connection information for.
Expanding a servername shows the datasources defined in its ColdFusion Administrator. You can drill down from Server to Datasource (schema) to the tables, to the fields. You can right-click a tableName and choose RDS Query Viewer and get a query builder, much like Microsoft Accesses, if you're familiar with that.
Alternatively you can just drag and drop tablenames and fieldnames directly into your hand-crafted code to save a lot of typing.
See Adobe Docs at http://help.adobe.com/en_US/ColdFusion/10.0/Developing/WSc3ff6d0ea77859461172e0811cbec16ab8-7ff9.html
There is also a CRUD creator described on that page, that can introspect a table and produce a CRUD cfc... not cruddy!
I want to be able to extract the form submissions from the Web Forms for marketers database and output it in an excel file I can make available to the public on demand.
Anyone know how I can do this?
I know they have an export to Excel option, but it is not automatic and requires someone to login and have access to the form.
I haven't been able to find any documentation from Sitecore on how to do this. Is this a supported operation? Do I have to reflect over the dlls to find api calls? Do I have to delve in to the SQL database and figure out how to do it manually? Is there no hope?
You might get lucky when using Reflector to disasamble the Sitecore.Forms dll. Try to find out if you can disassemble the code that get's run when clicking the Export button.
Actually:
The command comes from: Sitecore.Form.Core.Commands.Export
The executed code is in: Sitecore.Form.Core.Pipelines.Export.Excel
Good luck!
This writeup provides a very detailed account of how to do this if anyone else stumbles on this post. http://r-coding-sitecoreblog.blogspot.com/2011/11/extracting-data-from-sitecore-wffm.html
Hello You can use below given my blog URL to export data in CSV I have also written some blogs to export in XML and HTML on front end
http://sitecoretweaks.wordpress.com/2014/07/02/sitecore-export-to-csvexcel-of-web-form-for-marketers-form-wffm-reports/
You can find all blogs about export data
http://sitecoretweaks.wordpress.com/